package cn.com.yusys.yusp.message.service;

import java.util.Map;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * 
 * @项目名称:yusp-message-client
 * @类名称:MessageClient
 * @类描述:服务API调用客户端
 * @功能描述:
 * @创建人:wangyf10@yusys.com.cn
 * @创建时间:2018-05-11
 * @修改备注:
 * @修改日期		修改人员		修改原因
 * --------    --------		----------------------------------------
 * @version 1.0.0
 * @Copyright (c) 2018宇信科技-版权所有
 */
@FeignClient(fallback=MessageTypeServiceHystrix.class  ,name = "${service.feignclient.name.yusp-app-message:yusp-app-message}", path = "/api/template")
public interface MessageTypeService {
	
	/**
	 * 发送实时消息非模板
	 * @param param  必填{channelType:"email/mobile/system",users:"40,20",content:"XXX"}  选填{title:"标题"}
	 * @return  0：成功
	 */
	@SuppressWarnings("rawtypes")
    @RequestMapping(value = "/sendRealTimeMessageWithOutTemplate", method = RequestMethod.POST)
	public String sendRealTimeMessageWithOutTemplate(@RequestBody Map param);
	
	/**
	 * 发送实时消息含模板
	 * @param param 必填{messageType:"ssxdcs"} 选填{channelType:"",users:""}
	 * @return 0：成功
	 */
	@SuppressWarnings("rawtypes")
	@RequestMapping(value = "/sendRealTimeMessageWithTemplate", method = RequestMethod.POST)
	public String sendRealTimeMessageWithTemplate(@RequestBody Map param);
	
	/**
	 * 
	 * @param param 必填{messageType:"ssxdcs"}  选填{channelType:"",sendUserId:"关系订阅是必填"}
	 * @return 0：成功
	 */
	@SuppressWarnings("rawtypes")
	@RequestMapping(value = "/sendSubscribeMessage", method = RequestMethod.POST)
	public String sendSubscribeMessage(@RequestBody Map param);
}
